#ifndef GROUP_H
#define GROUP_H

#include<string>
#include<vector>
#include"groupuser.hpp"
using namespace std;


// 组表的ORM类
class Group{
public:
    Group(int id=-1,string name="", string desc = "")
    {
        this->id = id;
        this->name = name;
        this->desc = desc;
    }

    void setId(int id) { this->id = id;}
    void setName(string name){this->name = name;}
    void setDesc(string desc){this->desc = desc;}

    int getId() { return this->id;}
    string getName(){ return name;}
    string getDesc() { return desc;} 
    vector<GroupUser> &getUsers(){return this->users;}
protected:
    int id; //该组id
    string name;  //该组名字
    string desc; // 该组描述
    vector<GroupUser> users; // 该组的 组员信息
};

#endif